<include file="public@header" />
</head>
<body>
<style>
    ul.aaaaa {
        list-style: none;
        margin: 0;
        padding: 0;
        font-size: 0;
        letter-spacing: -4px;
        word-spacing: -4px;
		margin-top: 10px;
    }

    ul.aaaaa li {
        display: inline-block;
        font-size: 14px;
		width: 300px;
		background: #ffffff;
        padding: 10px;
		margin: 5px 20px 5px 0;
        letter-spacing: normal;
        word-spacing: normal;
    }
</style>
	<div class="wrap">
		<ul class="nav nav-tabs">
			<li class="active"><a>映票</a></li>
		</ul>
		<form class="well form-inline margin-top-20" method="post" action="">
			家族总映票：{$total_family}
			<br>
			主播总映票：{$total_anthor}
			<br>
			总映票：{$total}
			<br>
			<ul class="aaaaa">
			<foreach name="inlives" item="item" >
				<li>{$item['user']['user_nickname']}({$item.uid})：{$item['time']}</li>
			</foreach>
			</ul>
		</form>
		<form class="well form-inline margin-top-20" method="post" id="form_profit" action="{:url('Family/profit')}">
			<input type="hidden" name="uid" id="uid" value="{:input('request.uid')}">
			会员ID：
            <input class="form-control" type="text" name="anchor_uid" style="width: 200px;" value="{:input('request.anchor_uid')}"
                   placeholder="请输入会员ID">
			统计时间：
			<input class="form-control js-bootstrap-date" name="start_time" id="start_time" autocomplete="off" value="{:input('request.start_time')}" aria-invalid="false" style="width: 110px;"> -
            <input class="form-control js-bootstrap-date" name="end_time" id="end_time" autocomplete="off" value="{:input('request.end_time')}" aria-invalid="false" style="width: 110px;">
			<input type="submit" class="btn btn-primary" id="search_profit" value="搜索">
			<input type="button" class="btn btn-primary" id="explode_profit" value="导出">
		</form>
		<form method="post" class="js-ajax-form" >
			<table class="table table-hover table-bordered">
				<thead>
					<tr>
						<th>会员ID</th>
						<th>用户昵称</th>
						<!--<th>直播时长（分）</th>-->
						<th>主播映票</th>
						<th>家族映票</th>
						<th>总映票</th>
						<th>统计时间</th>
					</tr>
				</thead>
				<tbody>
					<foreach name="lists" item="vo">
					<tr>
						<td>{$vo.uid}</td>
						<td>{$vo['userinfo']['user_nickname']}</td>
						<!--<td>$vo['in_live']</td>-->
						<td>{$vo['profit_anthor']}</td>
						<td>{$vo['profit']}</td>
						<td>{$vo['total']}</td>
						<td>{:date('Y-m-d H:i:s',$vo['addtime'])}</td>
					</tr>
					</foreach>
				</tbody>
			</table>
			<div class="pagination">{$page}</div>

		</form>
	</div>
	<script src="__STATIC__/js/admin.js"></script>
	<script type="text/javascript">
		$("#explode_profit").click(function() {
			var formObj = $("#form_profit") ;
			formObj.action = "{:url('Family/profit_explode')}" ;//发送请求的路径
			formObj.method = "post" ; //表单请求的方式
			formObj.attr('action', "{:url('Family/profit_explode')}")
			//如果不设置上面的两个参数，默认提交触发该事件的表单
			formObj.submit() ; //表单提交
		}) ;

		$("#search_profit").click(function() {
			var formObj = $("#form_profit") ;
			formObj.action = "{:url('Family/profit')}" ;//发送请求的路径
			formObj.method = "post" ; //表单请求的方式
			formObj.attr('action', "{:url('Family/profit')}")
			//如果不设置上面的两个参数，默认提交触发该事件的表单
			formObj.submit() ; //表单提交
		}) ;
	</script>
</body>
</html>